package com.googlecode.hmvc4gwt.example.hmvcblog.server.repository.blog;

import java.util.List;

import com.googlecode.hmvc4gwt.example.hmvcblog.server.domain.blog.Blog;
import com.googlecode.hmvc4gwt.example.hmvcblog.server.domain.user.User;
import com.googlecode.hmvc4gwt.example.hmvcblog.server.repository.blog.exceptions.BlogNotFoundException;

public interface IBlogRepository {

	public Blog findByName(String name) throws BlogNotFoundException;
	
	public void addBlog(Blog blog);
	
	public void removeBlog(Blog blog) throws BlogNotFoundException;
	
	public List<Blog> getListBlogs();

	public Blog findById(int id) throws BlogNotFoundException;
	
	public List<Blog> getBlogsOfuser(User user);
	
	public Blog getBlogEdit(int id) throws BlogNotFoundException;

	public void update(Blog blog);
	
	
}
